package com.design.builder.computer;

/**
 * @author xiemiao
 * @description 销售员
 * @date 2023/08/15
 */
public class SalesMan {
    private ComputerBuilder computerBuilder;

    public SalesMan() {
    }

    public void setComputerBuilder(ComputerBuilder computerBuilder) {
        this.computerBuilder = computerBuilder;
    }

    public Computer getResult() {
        return computerBuilder.getComputer();
    }

    public void construct() {
        computerBuilder.buildCpu();
        computerBuilder.buildMemory();
        computerBuilder.buildStorage();
        computerBuilder.buildGraphicsCard();
    }
}
